| Conditions | 1 |
| Paths | 1 |
| Total Lines | 17 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 1 | Features | 0 |
| 1 | |||
| 24 | return new Promise((resolve, reject) => { |
||
| 25 | |||
| 26 | const element = window.document.createElement('script'); |
||
| 27 | |||
| 28 | element.onload = () => { |
||
| 29 | resolve(src); |
||
| 30 | }; |
||
| 31 | |||
| 32 | element.onerror = () => { |
||
| 33 | reject(new Error(src)); |
||
| 34 | }; |
||
| 35 | |||
| 36 | element.async = true === async; |
||
| 37 | element.src = src; |
||
| 38 | |||
| 39 | window.document.body.appendChild(element); |
||
| 40 | })/* .then((s) => { |
||
| 41 | |||
| 55 |
This check looks for parameters in functions that are not used in the function body and are not followed by other parameters which are used inside the function.